import UIKit

@available(iOS 6.0, *)
extension QKC where AA :UICollectionReusableView {
    open func reuseIdentifier_qk_g() -> QKC<AA,YY,ZZ, String? >{
		 self +^ self.value.reuseIdentifier
	}

	// Subclassers must call super.
    open func prepareForReuse_qk_f() -> QKC<AA,YY,ZZ,Void>{
		 self +^ self.value.prepareForReuse()
	}

	// Note that -applyLayoutAttributes: is only called when attributes change, as defined by -isEqual:.
    open func apply_qk_f(_ layoutAttributes: UICollectionViewLayoutAttributes) -> QKC<AA,YY,ZZ, UICollectionViewLayoutAttributes>{
		 self +^ self.value.apply(layoutAttributes) +^ layoutAttributes
	}

	// Override these methods to provide custom UI for specific layouts.
    open func willTransition_qk_f(from oldLayout: UICollectionViewLayout, to newLayout: UICollectionViewLayout) -> QKC<AA,YY,ZZ, UICollectionViewLayout>{
		 self +^ self.value.willTransition(from:oldLayout, to:newLayout) +^ oldLayout
	}

    open func didTransition_qk_f(from oldLayout: UICollectionViewLayout, to newLayout: UICollectionViewLayout) -> QKC<AA,YY,ZZ, UICollectionViewLayout>{
		 self +^ self.value.didTransition(from:oldLayout, to:newLayout) +^ oldLayout
	}

    @available(iOS 8.0, *)
    open func preferredLayoutAttributesFitting_qk_f(_ layoutAttributes: UICollectionViewLayoutAttributes) -> QKC<AA,YY,ZZ,UICollectionViewLayoutAttributes>{
		 self +^ self.value.preferredLayoutAttributesFitting(layoutAttributes)
	}

}

@available(iOS 6.0, *)
extension QKC where AA :UICollectionViewCell {
		// add custom subviews to the cell's contentView
    open func contentView_qk_g() -> QKC<AA,YY,ZZ, UIView >{
		 self +^ self.value.contentView
	}

	// The collection view may call the setters inside an animation block.
    open func isSelected_qk_s(_ isSelected:  Bool) -> QKC<AA,YY,ZZ, Bool>{
		return link(next: isSelected).then_QK { $0.value.isSelected = isSelected }
	}
    open func isSelected_qk_g() -> QKC<AA,YY,ZZ, Bool>{
		 self +^ self.value.isSelected
	}

    open func isHighlighted_qk_s(_ isHighlighted:  Bool) -> QKC<AA,YY,ZZ, Bool>{
		return link(next: isHighlighted).then_QK { $0.value.isHighlighted = isHighlighted }
	}
    open func isHighlighted_qk_g() -> QKC<AA,YY,ZZ, Bool>{
		 self +^ self.value.isHighlighted
	}

	// If selectedBackgroundView is different than backgroundView, it will be placed above the background view and animated in on selection.
    open func backgroundView_qk_s(_ backgroundView:  UIView?) -> QKC<AA,YY,ZZ, UIView?>{
		return link(next: backgroundView).then_QK { $0.value.backgroundView = backgroundView }
	}
    open func backgroundView_qk_g() -> QKC<AA,YY,ZZ, UIView?>{
		 self +^ self.value.backgroundView
	}

    open func selectedBackgroundView_qk_s(_ selectedBackgroundView:  UIView?) -> QKC<AA,YY,ZZ, UIView?>{
		return link(next: selectedBackgroundView).then_QK { $0.value.selectedBackgroundView = selectedBackgroundView }
	}
    open func selectedBackgroundView_qk_g() -> QKC<AA,YY,ZZ, UIView?>{
		 self +^ self.value.selectedBackgroundView
	}

	//
    @available(iOS 11.0, *)
    open func dragStateDidChange_qk_f(_ dragState: UICollectionViewCell.DragState) -> QKC<AA,YY,ZZ, UICollectionViewCell.DragState>{
		 self +^ self.value.dragStateDidChange(dragState) +^ dragState
	}

}

